PV-on-HVM: Implement and export a compatibility version of do_exit().
authorIan Campbell <ian.campbell@xensource.com>
Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)
committerIan Campbell <ian.campbell@xensource.com>
Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)
Kernels prior to 2.6.12 did not export do_exit().

Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
unmodified_drivers/linux-2.6/platform-pci/platform-compat.c

index f13d54b15c80f2e07eaef43bc82ecd471a341817..2df38d806bd0d11a76466ac8f4c987b02a58344f 100644 (file)
@@ -73,3 +73,18 @@ out:
 }
 EXPORT_SYMBOL(wait_for_completion_timeout);
 #endif
+
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,12)
+/*
+    fake do_exit using complete_and_exit
+ */
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,10)
+asmlinkage NORET_TYPE void do_exit(long code)
+#else
+fastcall NORET_TYPE void do_exit(long code)
+#endif
+{
+    complete_and_exit(NULL, code);
+}
+EXPORT_SYMBOL_GPL(do_exit);
+#endif